Skip to content

fix: skip init prompts when stdin is not a TTY - #16

Open
manish-wekan wants to merge 1 commit into
mainfrom
fix/cli-skip-init-prompts-non-tty
Open

fix: skip init prompts when stdin is not a TTY#16
manish-wekan wants to merge 1 commit into
mainfrom
fix/cli-skip-init-prompts-non-tty

Conversation

@manish-wekan

Copy link
Copy Markdown
Collaborator

Summary

  • Skip Description/Author prompts in nitrostack-py init when stdin is not a TTY, so NitroStudio generate (step 4 of 5) and CI cannot hang on readline().
  • --skip-install still only skips dependency install; this change is the missing non-interactive path.
  • If the target directory already exists and stdin is not a TTY, exit 1 instead of prompting to overwrite.
  • Add isolated CLI tests that leave stdin open and never write, matching Studio's inherited-stdin hang.

Test plan

  • python -m pytest tests/test_cli_studio_noninteractive.py
  • python -m nitrostack.cli.main init demo --template python-starter --skip-install with stdin closed completes without prompts
  • Interactive TTY init still asks Description/Author
  • NitroStudio generate Python project no longer hangs on step 4 of 5

Made with Cursor

@manish-wekan
manish-wekan added this pull request to stack #32 September 10, 2026 12:33
Base automatically changed from develop to main September 10, 2026 12:35
Studio and CI inherit an open stdin that never writes, so Description/Author readline hung generate. Use defaults off-TTY and refuse overwrite without a prompt.
@manish-wekan
manish-wekan force-pushed the fix/cli-skip-init-prompts-non-tty branch from 88d4de1 to b61b84f Compare September 10, 2026 12:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant